//- Copyright (c) 2016 Lucky Byte, Inc.
extends ../table

append scripts
  script(src="/js/trstat/trstat.js")

block form_items
  .field.two.wide
    .ui.calendar.date#start_date(data-end-with="#end_date"
      data-maxdate="#{today()}")
      .ui.input.left.icon
        i.calendar.icon
        input(type="text" name="start_date" placeholder="起始日期"
          value="#{start_date || ''}")
  .field.two.wide
    .ui.calendar.date#end_date(data-start-with="#start_date"
      data-maxdate="#{today()}")
      .ui.input.right.icon
        input(type="text" name="end_date" placeholder="结束日期"
          value="#{end_date || ''}")
        i.remove.link.icon#date_clear

block gap
  .ui.attached.segment
    .ui.small.breadcrumb(style="float:right;")
      i.right.chevron.icon.divider
      .ui.dropdown.simple
        .text(style="color:#888;") 交易汇总
        i.dropdown.icon.blue
        .menu
          .item.nav.with.date(data-href="/trstat/trcodes") 交易按类型汇总
          .item.nav.with.date(data-href="/trstat/merch") 交易按商户汇总
      i.ellipsis.vertical.icon.divider
      .ui.dropdown.simple
        .text(style="color:#888;") 消费代付
        i.dropdown.icon.blue
        .menu
          .item.nav.with.date(data-href="/trstat/p1_order") 消费代付明细
          .item.nav.with.date(data-href="/trstat/p1_order_sum") 消费代付汇总
      i.ellipsis.vertical.icon.divider
      .ui.dropdown.simple
        .text(style="color:#888;") 助农代付
        i.dropdown.icon.blue
        .menu
          .item.nav.with.date(data-href="/trstat/p2_order") 助农取款代付明细
          .item.nav.with.date(data-href="/trstat/p2_order_sum") 助农取款代付汇总
          .item.nav.with.date(data-href="/trstat/p2_fund_sum") 资金池变更汇总
      i.ellipsis.vertical.icon.divider
      .section
        a.nav.with.date(href="#" data-href="/trlist") 交易流水

    h2.ui.header.center.aligned.nolayout= stat_title
